{extend name='public/form'/}
{block name='fields'}
{:token_field()}
<div class="layui-form-item">
    <label class="layui-form-label">字段名</label>
    <div class="layui-input-inline">
        <select name="sid" lay-verify="required">
            <option value=""></option>
            {foreach $setting as $key => $vo}
            <option value="{$key}">{$vo}</option>
            {/foreach}
        </select>
    </div>
</div>
<div class="layui-form-item">
    <label class="layui-form-label">标签名</label>
    <div class="layui-input-block">
        <input type="text" name="label" value="" autocomplete="off" class="layui-input">
    </div>
</div>
<div class="layui-form-item">
    <label class="layui-form-label">类型</label>
    <div class="layui-input-inline">
        <select name="type" lay-verify="required">
            <option value=""></option>
            <option value="text">文本框</option>
            <option value="password">密码框</option>
            <option value="number">数字框</option>
            <option value="textarea">文本域</option>
            <option value="upload">上传框</option>
            <option value="color">颜色框</option>
            <option value="date">日期框</option>
            <option value="select">选择框</option>
            <option value="radio">单选框</option>
            <option value="checkbox">复选框</option>
            <option value="switch">开关</option>
            <option value="editor">layEditor</option>
            <option value="weditor">wangEditor</option>
        </select>
    </div>
</div>
<div class="layui-form-item">
    <label class="layui-form-label">名称</label>
    <div class="layui-input-block">
        <input type="text" name="name" value="" required lay-verify="required" placeholder="请输入名称"
            autocomplete="off" class="layui-input">
    </div>
</div>
<div class="layui-form-item">
    <label class="layui-form-label">默认值</label>
    <div class="layui-input-inline">
        <input type="text" name="value" value="" autocomplete="off" class="layui-input">
    </div>   
</div>
<div class="layui-form-item layui-form-text">
    <label class="layui-form-label">options</label>
    <div class="layui-input-block">
        <textarea name="options" class="layui-textarea" placeholder="选择框、单选框和复选框及默认值填写json字符串"></textarea>
    </div>
</div>
<div class="layui-form-item">
    <label class="layui-form-label">描述信息</label>
    <div class="layui-input-block">
        <input type="text" name="desc" value="" autocomplete="off" class="layui-input">
    </div>
</div>
<div class="layui-form-item">
    <label class="layui-form-label">排序</label>
    <div class="layui-input-inline">
        <input type="number" name="ord" value="0" required lay-verify="required|max:4" placeholder="请输入排序"
            autocomplete="off" class="layui-input">
    </div>
</div>
<div class="layui-form-item">
    <label class="layui-form-label">状态</label>
    <div class="layui-input-block">
        <input type="hidden" name="status" value="1">
        <input type="checkbox" name="status" value="0" checked lay-text="开启|禁用"
            lay-skin="switch">
    </div>
</div>
{/block}